﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using PJ.Framework.Common;
using PJ.Business.SalePurchase.Sale;
using Microsoft.Practices.Composite.Events;
using PJ.Business;
using PJ.Presentation.Partner;
using Microsoft.Practices.Composite.Wpf.Events;

namespace PJ.Presentation.SalePurchase.Sale
{
    public class CustomerShoppingCartModel : ShoppingCartModel<CustomerShoppingCartItemModel>, ICustomerShoppingCartModel
    {
        public CustomerShoppingCartModel()
            : base(null, null, null, null)
        {
        }

        [Microsoft.Practices.Unity.InjectionConstructor]
        public CustomerShoppingCartModel(ICustomerShoppingCartView view, IEventAggregator aggregator, ICustomerShoppingCartService service, ICustomerShoppingCartItemService itemService)
            : base(view, aggregator, service, itemService)
        {
            EventAggregator.GetEvent<CustomerIDChangeEvent>().Subscribe(ChangePartner, ThreadOption.UIThread);
        }
        
    }
}
